package com.financing.wap.dao.impl;


import java.sql.SQLException;
import java.util.List;
import java.util.Map;
import org.springframework.stereotype.Repository;
import com.financing.wap.dto.DstUserClientTagInfoDTO;
import com.financing.wap.dao.IDstUserClientTagInfoDao;
import com.financing.wap.common.SqlName;
/**
 * dst_user_client_tag_info  
 * 用户客户标签信息 数据访问层实现类
 * @author huqiyun
 *
 */
 
@Repository("dstUserClientTagInfoDao")
public class DstUserClientTagInfoDaoImpl extends BaseDaoImpl<DstUserClientTagInfoDTO, java.lang.Integer> implements IDstUserClientTagInfoDao {


	@Override
	public int insert(DstUserClientTagInfoDTO dstUserClientTagInfo) throws SQLException {
		return (Integer) this.sqlMapClientTemplate.insert(SqlName.DstUserClientTagInfoSql.insert, dstUserClientTagInfo);
	}

	@Override
	public void update(DstUserClientTagInfoDTO dstUserClientTagInfo) throws SQLException {
		this.sqlMapClientTemplate.update(SqlName.DstUserClientTagInfoSql.update, dstUserClientTagInfo);
	}

	@Override
	public void updateForce(DstUserClientTagInfoDTO dstUserClientTagInfo) throws SQLException {
		this.sqlMapClientTemplate.update(SqlName.DstUserClientTagInfoSql.updateForce, dstUserClientTagInfo);
	}

	@Override
	public void delete(Integer id) throws SQLException {
		this.sqlMapClientTemplate.delete(SqlName.DstUserClientTagInfoSql.delete,id);
	}
	
	@SuppressWarnings("unchecked")	
	@Override
	public List<DstUserClientTagInfoDTO> queryList(DstUserClientTagInfoDTO dstUserClientTagInfo) throws SQLException {
		return this.sqlMapClientTemplate.queryForList(SqlName.DstUserClientTagInfoSql.queryList, dstUserClientTagInfo);
	}

	@Override
	public int queryListCount(DstUserClientTagInfoDTO dstUserClientTagInfo) throws SQLException {
		return (Integer) this.sqlMapClientTemplate.queryForObject(SqlName.DstUserClientTagInfoSql.queryListCount, dstUserClientTagInfo);
	}

	@Override
	public DstUserClientTagInfoDTO loadById(Integer id) throws SQLException {
		return  (DstUserClientTagInfoDTO)this.getSqlMapClientTemplate().queryForObject(SqlName.DstUserClientTagInfoSql.loadById,id);
	}

	@Override
	public Class<DstUserClientTagInfoDTO> getEntityClass() {
		return DstUserClientTagInfoDTO.class;
	}
 	
}
